package edu.fim.core.util;


public enum BmiCategories {
	
	WAY_UNDERWEIGHT (0.0, 17.0),
	UNDERWEIGHT (17.0, 18.49),
	NORMAL_WEIGHT (18.5, 24.99),
	OVERWEIGHT (25.0, 29.99),
	OBESITY (30.0, 34.99),
	SEVERE_OBESITY (35.0, 39.9),
	MORBID_OBESITY (40.0, Double.MAX_VALUE);
	
	private Double initialValue;
	private Double lastValue;
	
	private BmiCategories(
			Double initialValue,
			Double lastValue) {
		this.initialValue = initialValue;
		this.lastValue = lastValue;
	}
	
	public boolean hasValue(Double imcValue) {
		if (imcValue > initialValue && imcValue <= lastValue) {
			return true;
		}
		return false;
	}
}